package com.yanqu.road.dataHelper.repair.mgr;

import com.yanqu.road.utils.string.StringUtils;

import java.util.UUID;

public class UUIDHelper {
	public synchronized static String saveRandomUUID(String prefix){
		String result;
		UUID uuid = UUID.randomUUID();
		if(StringUtils.isNullOrEmpty(prefix)){
			result = uuid.toString();
		}else {
			result = prefix + "-" + uuid.toString();
		}
		return result;
	}

}
